package com.heima.model.mango.pojos;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;

import java.io.Serializable;
import java.util.Date;

@AllArgsConstructor
@NoArgsConstructor
@Data
@Document("ap_comment")
public class Comment implements Serializable {
    private static final long serialVersionUID = 1L;
    /**
     * 文章ID
     */
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long entryId;
    /**
     *评论内容
     */
    private String content;
    /**
     * 用户ID
     */
    private Integer authorId;
    /**
     * 评论ID
     */
    private String id;
    /**
     * 评论时间
     */
    private Date createdTime;

    /**
     * 用户昵称
     */
    private String authorName;
    /**
     * 点赞数量
     */
    private Integer likes;
    /**
     * 回复数量
     */
    private Integer reply;
    /**
     * 暂时不知道是什么
     */
    private Integer type;
    /**
     *用户头像
     */
    private String image;
    /**
     * 标识该用户是否点赞,0为已点赞，1 取消点赞  null 未点赞
     */
    private Short operation;
}
